import { get } from '@/utils/request';

export interface PageParams {
  current: number;
  pageSize: number;
}

export interface MyMessageData {
  id: string;
  avatar: string;
  title: string;
  createdTime: string;
  readCount: string;
  publisher: string;
}

export interface MyMessageDetail {
  id: string;
  contents: string[];
  attachments: string[];
}
export interface MyMessageRecord {
  list: MyMessageData[];
  total: number;
}

export function queryMessageList(params: PageParams) {
  return get<MyMessageRecord>('/api/message/getList', params);
}
